import request from '@/utils/request'

// 车辆管理列表
export const carManageListAPI = () => {
  return request({
    url: '/truckType/simple'
  })
}
// 车辆管理分页数据
export const carManagePagingAPI = (params) => {
  return request({
    url: '/truckType/page',
    params
  })
}
// 新增车辆类型
export const addCarAPI = (data) => {
  return request({
    url: '/truckType',
    method: 'POST',
    data
  })
}
// 删除车辆类型
export const delCarAPI = (id) => {
  return request({
    url: `/truckType/${id}`,
    method: 'DELETE'

  })
}
// 车辆类型详情
export const carDetailsAPI = (id) => {
  return request({
    url: `/truckType/${id}`
  })
}
// 编辑车辆类型
export const editVehicleAPI = (data) => {
  return request({
    url: `/truckType/${data.id}`,
    method: 'PUT',
    data
  })
}
